using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

using FlickrNet;

namespace FlickrManager
{
    public partial class Thumb : System.Web.UI.UserControl
    {
        /// <summary>
        /// Handles the Load event of the Page control.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param>
        protected void Page_Load(object sender, EventArgs e)
        {
        }

        /// <summary>
        /// Sets the set photo.
        /// </summary>
        /// <value>The set photo.</value>
        public Photo SetPhoto
        {
            set
            {
                Photo photo = value;
                image.Alt = photo.Title;
                image.Attributes["title"] = photo.Title;
                image.Src = photo.ThumbnailUrl;

                myhref.HRef = "Default.aspx?group=" + Request.QueryString["group"] + "&name=" + 
                    Request.QueryString["name"] + "&imageUrl=" + photo.PhotoId + "&groupPage=" + 
                    Request.QueryString["groupPage"] + "&setPage="+ Request.QueryString["setPage"]+"&userId="+photo.UserId;
            }
        }
    }
}